import request from '@/utils/request'

export function publishPost(data) {
    return request({
        url: '/publish/post',
        method: 'post',
        data: data
    })
}

export function UploadFile(image) {
    return request({
        url: '/upload/file',
        method: 'post',
        data: {
            image: image
        }
    })
}

export function getTagsData() {
    return request({
        url: '/publish/tags',
        method: 'get'
    })
}

export function updatePost(data) {
    return request({
        url: '/publish/update',
        method: 'post',
        data: data,
    })
}